package acwing._2LanQiao._11No11;
/**
 * @Project : AlgorithmLearning
 * @Package : ACWing._2LanQiao._11No11
 * @File : Q2065.java
 * @Author : WangRuoyu
 * @Date : 2023/3/27 17:02
 */

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Q2065 {
    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String[] words = br.readLine().split(" ");

        long n = Long.parseLong(words[0]);
        while (n > 0) {
            System.out.print(n + " ");
            n /= 2;
        }
    }
}